package com.china08.yxyapi.entity.db.sws;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

import com.china08.yxyapi.entity.BaseEntity;

/**
 * 模版和模块的对应关系
 * 
 * @author Ertao.Fang
 * 
 */
@Entity
@Table(name = "sws_school_templet", catalog = "yxy_sws", uniqueConstraints = { @UniqueConstraint(columnNames = { "school_id", "template_id", "module_id" }) })
public class SwsSchoolTemplet extends BaseEntity {

    private static final long serialVersionUID = -3591045310843550193L;

    /** 学校id */

    @Column(name = "school_id", nullable = false, columnDefinition = "varchar(255) COMMENT '学校id'")
    private String schoolId;

    /** 模版id */
    @Column(name = "template_id", nullable = false)
    private String templateId;

    /**
     * 模块id，将所有模块id存储在此字段
     */
    @Column(name = "module_id", length = 256, nullable = false)
    private String moduleId;

    /** 排列序号 **/
    @Column(name = "order_num", columnDefinition = "INT(11) DEFAULT 100", nullable = false)
    private Integer orderNum = 100;

    public String getSchoolId() {
        return schoolId;
    }

    public void setSchoolId(String schoolId) {
        this.schoolId = schoolId;
    }

    public String getTemplateId() {
        return templateId;
    }

    public void setTemplateId(String templateId) {
        this.templateId = templateId;
    }

    public String getModuleId() {
        return moduleId;
    }

    public void setModuleId(String moduleId) {
        this.moduleId = moduleId;
    }

    public Integer getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(Integer orderNum) {
        this.orderNum = orderNum;
    }
}
